package com.zccx.eth.model.em;

/**
 * @author Jian
 * @description
 * @created 2018/4/9 15:27.
 */
public enum UserType {

    /**
     * 学生
     * Student teacher
     */
    STUDENT("1"),
    /**
     * 教师
     */
    TEACHER("2");

    private String value;

    private UserType(String value) {
        this.value = value;
    }

    public String getValue() {
        return value;
    }

    /**
     * convert String type to AccountType
     *
     * @param value
     */
    public static UserType parse(String value) {
        UserType photoType = null;
        for (UserType obj : UserType.values()) {
            if (obj.getValue().equals(value)) {
                photoType = obj;
                break;
            }
        }
        return photoType;
    }


}
